package com.zan.principles.demo3.after;

/**
 * @Author Zan
 * @Create 2024/4/22 21:26
 * @Description : TODO(请用一句话描述该类的功能)
 * @ClassName: ComputerDemo
 */
public class ComputerDemo {
    public static void main(String[] args) {
        HardDisk hardDisk = new XiJieHardDisk();
        Cpu cpu = new IntelCpu();
        Memory memory = new KingstonMemory();

        Computer computer = new Computer();
        computer.setHardDisk(hardDisk);
        computer.setCpu(cpu);
        computer.setMemory(memory);

        computer.run();
    }
}
